Optimal. Leaf size=28 \[ \frac {(a-b) \sin (c+d x)}{d}+\frac {b \tanh ^{-1}(\sin (c+d x))}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.03, antiderivative size = 28, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.158, Rules used = {3676, 388, 206} \[ \frac {(a-b) \sin (c+d x)}{d}+\frac {b \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rule 388
Rule 3676
Rubi steps
\begin {align*} \int \cos (c+d x) \left (a+b \tan ^2(c+d x)\right ) \, dx &=\frac {\operatorname {Subst}\left (\int \frac {a-(a-b) x^2}{1-x^2} \, dx,x,\sin (c+d x)\right )}{d}\\ &=\frac {(a-b) \sin (c+d x)}{d}+\frac {b \operatorname {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\sin (c+d x)\right )}{d}\\ &=\frac {b \tanh ^{-1}(\sin (c+d x))}{d}+\frac {(a-b) \sin (c+d x)}{d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.03, size = 47, normalized size = 1.68 \[ \frac {a \sin (c) \cos (d x)}{d}+\frac {a \cos (c) \sin (d x)}{d}-\frac {b \sin (c+d x)}{d}+\frac {b \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.56, size = 44, normalized size = 1.57 \[ \frac {b \log \left (\sin \left (d x + c\right ) + 1\right ) - b \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (a - b\right )} \sin \left (d x + c\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 1.49, size = 48, normalized size = 1.71 \[ \frac {b {\left (\log \left ({\left | \sin \left (d x + c\right ) + 1 \right |}\right ) - \log \left ({\left | \sin \left (d x + c\right ) - 1 \right |}\right ) - 2 \, \sin \left (d x + c\right )\right )} + 2 \, a \sin \left (d x + c\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.37, size = 44, normalized size = 1.57 \[ \frac {a \sin \left (d x +c \right )}{d}-\frac {b \sin \left (d x +c \right )}{d}+\frac {b \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.32, size = 46, normalized size = 1.64 \[ \frac {b {\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right ) - 2 \, \sin \left (d x + c\right )\right )} + 2 \, a \sin \left (d x + c\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 11.87, size = 32, normalized size = 1.14 \[ \frac {\sin \left (c+d\,x\right )\,\left (a-b\right )}{d}+\frac {2\,b\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \tan ^{2}{\left (c + d x \right )}\right ) \cos {\left (c + d x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________